package com.retail.lottery.colalottery.job.order;
import com.retail.lottery.colalottery.utils.NetWorkUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.DependsOn;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;
import javax.annotation.Resource;

@Slf4j
@Component
@DependsOn("redisUtils")  // 确保beanB先初始化
public class OrderDetailJob {

    @Resource
    private OrderDetailDealStrategyService orderDetailDealStrategyService;

    @PostConstruct
    public void init() {
        executeDealStatus();
    }

    @Scheduled(cron = "0/30 * * * * ?")
    private void executeDealStatus() {
        orderDetailDealStrategyService.dealOrderDetail();
    }



}
